import request from '@/utils/request'

export function getClassList(data) {
  return request({
    url: '/class/selectAll',
    method: 'get',
    params: data,
  })
}

export function getClassById(data) {
  return request({
    url: `/class/select/${data.id}`,
    method: 'get',
    params: data,
  })
}

export function updateClass(data) {
  return request({
    url: '/class/update',
    method: 'put',
    data,
  })
}

export function insertClass(data) {
  return request({
    url: '/class/insert',
    method: 'post',
    data,
  })
}
/**
 * 查询所有班级
 * @param
 * @returns
 */
export function getClassAll() {
  return request({
    url: '/class/getList',
    method: 'get'
  })
}
